package Day03;

import java.util.Scanner;

public class IfDemo {
    public static void main(String[] args) {
        double price = 550;
        Scanner sc = new Scanner(System.in);
        System.out.println("请输入购物金额:");
        price = sc.nextDouble();
        if(price >= 500){
            price *= 0.8;
        }
        System.out.println("价格为" + price);
    }
}
